From: Stefan Monnier Date: Sat, 12 Oct 2002 22:08:20 +0000 (+0000) Subject: (Fread_file_name): Use empty_string. Use if-expr to simplify. X-Git-Tag: archive/raspbian/1%29.2+1-2+rpi1^2~5^2~54951 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:///%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:/?a=commitdiff_plain;h=4a9f0faea66f0bf6f6523c00041da84e0ba43531;p=emacs.git (Fread_file_name): Use empty_string. Use if-expr to simplify. --- diff --git a/src/fileio.c b/src/fileio.c index e48776b18a4..2e83159ef86 100644 --- a/src/fileio.c +++ b/src/fileio.c @@ -6023,12 +6023,9 @@ provides a file dialog box. */) if (NILP (dir)) dir = current_buffer->directory; if (NILP (default_filename)) - { - if (! NILP (initial)) - default_filename = Fexpand_file_name (initial, dir); - else - default_filename = current_buffer->filename; - } + default_filename = !NILP (initial) + ? Fexpand_file_name (initial, dir) + : current_buffer->filename; /* If dir starts with user's homedir, change that to ~. */ homedir = (char *) egetenv ("HOME"); @@ -6154,7 +6151,7 @@ provides a file dialog box. */) if (! replace_in_history) add_to_history = 1; - val = build_string (""); + val = empty_string; } unbind_to (count, Qnil);